package homewoek12月19号.homwwork.h3;

import org.apache.commons.beanutils.BeanUtils;

import java.lang.reflect.InvocationTargetException;
import java.util.HashMap;

public class MainApp {
    public static void main(String[] args) throws InvocationTargetException, IllegalAccessException {
        HashMap<String, String[]> map = new HashMap<>();
        map.put("loginName",new String[]{"西西"});
        map.put("password",new String[]{"123456"});
        map.put("sex",new String[]{"女"});
        map.put("esu",new String[]{"研究生"});
        map.put("arr",new String[]{"读书”,”唱歌”,”旅游”"});
        User user = new User();
        BeanUtils.populate(user,map);
        System.out.println(user);
    }
}
